//
// Created by lwj66 on 24-6-21.
//
#include "assert.h"
#include "stdlib.h"

#define NAME_MAX 100
#define SEX_MAX 4
#define TEL_MAX 11
#define ADDR_MAX 100

typedef struct PersonInfo
{
    char name[NAME_MAX];
    char sex[SEX_MAX];
    int age;
    char tel[TEL_MAX];
    char addr[ADDR_MAX];
}PeoInfo;

typedef struct contact
{
    PeoInfo* pi;
    struct contact* next;
}con;

void contactInit(con** c)
{
    assert(c);
    *c = (con*) malloc(sizeof (con));
    if(!(*c))
    {
        perror("分配地址失败!");
        exit(1);
    }

}
